package com.zerdoor.service.impl;

import com.zerdoor.dao.RbacOperatingDao;
import com.zerdoor.service.RbacOperatingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * Created by xiaoji on 2015/2/2.
 */
@Service
public class RbacOperatingServiceImpl implements RbacOperatingService {
    @Autowired
    private RbacOperatingDao rbacOperatingDao;

    /**
     * 获取操作码
     *
     * @param map 操作查询条件
     * @return
     */
    @Override
    public List<Map<String, Object>> getRbacOperating(Map<String, Object> map) {
        return rbacOperatingDao.getRbacOperating(map);
    }

    /**
     * 添加操作码
     *
     * @param map
     * @throws Exception
     */
    @Override
    public void addRbacOperating(Map<String, Object> map) throws Exception {
        rbacOperatingDao.addRbacOperating(map);
    }

    /**
     * 修改操作码
     *
     * @param map
     * @throws Exception
     */
    @Override
    public void updateRbacOperating(Map<String, Object> map) throws Exception {
        rbacOperatingDao.updateRbacOperating(map);
    }

    /**
     * 编辑操作码
     *
     * @param opId
     * @throws Exception
     */
    @Override
    public void deleteRbacOperating(int opId) throws Exception {
        rbacOperatingDao.deleteRbacOperating(opId);
    }
}
